package nnweboa;

import java.sql.Timestamp;

public class Userinfo {

	private long id;
	private String mail;
	private String password;
	private int right;
	private Timestamp modifydate;
	private String name;
	private int freeze;

	public String getPassword() {
		return password;
	}

	public int getRight() {
		return right;
	}

	public void setId(long id) {
		this.id = id;

	}

	public String getMail() {
		return mail;
	}

	public String getName() {
		return name;
	}

	public void setmail(String mail) {
		// TODO Auto-generated method stub
		this.mail = mail;

	}

	public void setpassword(String password) {
		// TODO Auto-generated method stub
		this.password = password;

	}

	public void setName(String name) {
		this.name = name;

	}

	public void setright(int right) {
		// TODO Auto-generated method stub
		this.right = right;

	}

	public void setmodifydate(Timestamp modifydate) {
		// TODO Auto-generated method stub
		this.modifydate = modifydate;

	}
	public String  getRightChinese() {
		 if(  getRight() ==  User.Boss)
		 {
			 return  "老板";
		 }
		 
		 if(  getRight() ==  User.DPManager)
		 {
			 return  "部门管理经理";
		 }
		 if(  getRight() ==  User.Worker)
		 {
			 return  "市场部部员";
		 }
		 if(  getRight() ==  User.Finacial)
		 {
			 return  "财务";
		 }
		 if(  getRight() ==  User.NTManager)
		 {
			 return  "网络管理员";
		 }
		return "错误";
		
	}

	public long getId() {
		// TODO Auto-generated method stub
		return id;
	}

	public Timestamp getModifyTime() {
		// TODO Auto-generated method stub
		return modifydate;
	}

	public void setFreeze(int freeze) {
		// TODO Auto-generated method stub
		this.freeze = freeze;
		
	}

	public int getFreeze() {
		// TODO Auto-generated method stub
		return freeze;
	}

}
